package com.stillalive.springcaptcha.model;

import lombok.Data;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.context.annotation.Configuration;

@Configuration
@Data
@ConfigurationProperties(prefix = "captcha")
public class CaptchaProperties {
    private int length;
    private int heigh;
    private Session session;

    // Spring不能管理内部类，因此这里写作静态内部类（相当于放在类外）
    @Data
    public static class Session{
        private String key;
        private String date;
    }
}
